 function CreateDesktop(){
 	function CreateAppSwitcher(){
		switcher=document.createElement("div")
		$(switcher).addClass("app-switcher")
		return switcher
	}
	function CreatePopWindow(){
		var popWin=document.createElement("div")
		var close=document.createElement("button")
		var container=document.createElement("div")
		$(close).click(function(){
			popWin.close()
		})
		popWin.close=function(){
			$(popWin).toggleClass("popup",false)
			$(container).empty()
		}
		popWin.setElement=function(element){
			$(container).empty()
			$(container).append(element)
			$(popWin).toggleClass("popup",true)
		}
		$(close).addClass("close")
		$(container).addClass("container")
		$(popWin).append(close)
		$(popWin).append(container)
		
		close.textContent="Close"
		return popWin
	}
	var desktop=document.createElement("div")
	var appName=document.createElement("p")
	var info=document.createElement("div")
	var hostName=document.createElement("p")
	var osName=document.createElement("p")
	var appAnchor=document.createElement("div")
	var appControlPanel=document.createElement("div")
	var appSwitcher=CreateAppSwitcher()
	var popWin=CreatePopWindow()
	var head=document.createElement("div")
	desktop.addApp=function (app){
		$(app).addClass("app")
		len=desktop.appList.length
		desktop.appList[len]=app
		if(desktop.appList.length>=1){
			$(appSwitcher).toggleClass("have-app",true)
		}
		$(desktop).append(app)
	}
	desktop.popWindow=popWin
	desktop.load=function(app){
		var controler=app.getControlElement()
		$(desktop).toggleClass("show",false)
		appName.textContent=app.getAppName()
		$(desktop).attr("app-name",app.getAppNameS())
		$(appControlPanel).append(controler)
		$(appAnchor).append(app.getMainContain)
		$(controler).addClass("app-controler")
		$(controler).addClass(app.getAppNameS())
		$(appAnchor).removeClass();
		$(appAnchor).addClass("app-anchor");
		$(appAnchor).addClass(app.getAppNameS())
		$(app).toggleClass("show",true)
		app.popWindow=desktop.popWindow
	}
	$(desktop).addClass("desktop")
	$(hostName).addClass("host-name")
	$(osName).addClass("os-name")
	$(appName).addClass("app-name")
	$(appControlPanel).addClass("control-panel")
	$(appAnchor).addClass("app-anchor")
	$(head).addClass("head")
	$(info).addClass("info")
	$(popWin).addClass("pop-window")
	
	$(desktop).append(appControlPanel)
	$(desktop).append(appAnchor)
	
	$(appControlPanel).append(head)
	$(appControlPanel).append(popWin)
	
	$(head).append(appName)
	$(head).append(info)
	
	$(info).append(hostName)
	$(info).append(osName)
	$(head).append(appSwitcher)
	
	desktop.appList=Array()
	hostName.textContent=fsystem.HostName
	osName.textContent=fsystem.OS
	
	return desktop
 }
